package com.micro.service.model;

import com.micro.service.annotation.QueryField;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.UUID;

/**
 * Create by Vic Xu on 2019/3/9
 */
@Document
public class UserArticle {

//    @QueryField
    @Id
    private String id;

//    @QueryField
    private String cardId;

//    @QueryField
    private String article;

    public UserArticle() {
    }

    public UserArticle(String cardId, String article) {
        this.id = UUID.randomUUID().toString();
        this.cardId = cardId;
        this.article = article;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getCardId() {
        return cardId;
    }

    public void setCardId(String cardId) {
        this.cardId = cardId;
    }

    public String getArticle() {
        return article;
    }

    public void setArticle(String article) {
        this.article = article;
    }
}
